﻿using Abp.Application.Services;
using Abp.Domain.Repositories;
using Batman.Cms.Core.Models.Mvc;
using Batman.Cms.Domains;
using Batman.Cms.Services.Applications.Inputs;

namespace Batman.Cms.Services.Applications
{
    public class ApplicationDataManager : ApplicationService
    {
        public IRepository<ApplicationData> Repository { get; set; }

        public ResponseBase Create(CreateApplicationDataInput model)
        {
            var entiry = ObjectMapper.Map<ApplicationData>(model);
            Repository.Insert(entiry);

            return new ResponseBase(true);
        }
    }
}
